package com.digital.library.modules.system.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 系统日志对象
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class SysLog implements Serializable {

	private static final long serialVersionUID = 1L;

	/*主键*/
	private int id;

	/*耗时*/
	private Long costTime;

	/*IP*/
	private String ip;

	/*请求参数*/
	private String requestParam;

	/*请求类型*/
	private String requestType;

	/*请求路径*/
	private String requestUrl;

	/*请求方法*/
	private String method;

	/*操作人用户名称*/
	private String username;

	/*操作人用户账户*/
	private String userid;

	/*操作详细日志*/
	private String logContent;

	/*日志类型（0_操作日志；1_登录日志）*/
	private Integer logType;

	/*操作类型（1查询，2添加，3修改，4删除,5导入，6导出）*/
	private Integer operateType;

	/*创建人*/
	private String createBy;

	/*创建时间*/
	@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
	private Date createTime;

	/*更新人*/
	private String updateBy;

	/*更新时间*/
	@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
	private Date updateTime;

}
